package com.bjut.dailyserver.controller;

import com.bjut.dailyserver.dao.NewsDetailDao;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@RequestMapping("/newsDetail")
public class NewsDetailController {
    @Autowired
    NewsDetailDao newsDetailDao;

    @RequestMapping("/findNewsById")
    @ResponseBody
    public Object findById(int id) { return newsDetailDao.findById(id); }
}
